<?php
/**
 * 值传递  和 引用传递
 */
echo "========值传递====","<br/>";
$a1 = "a1";
$a2 = $a1;
echo "a1=",$a1,"<br/>";
echo "a2=",$a2,"<br/>";
echo "改变a2的值","<br/>";
$a2 = "change the value of a2";
echo "a1=",$a1,"<br/>";
echo "a2=",$a2,"<br/>";

echo "========引用传递====","<br/>";
$b1 = "b1";
//这里多一个 & 代表 引用传递
$b2 = &$b1;
echo "b1=",$b1,"<br/>";
echo "b1=",$b1,"<br/>";
echo "改变b2的值","<br/>";
$b2 = "change the value of b2";
echo "b1=",$b1,"<br/>";
echo "b2=",$b2,"<br/>";
?>